/*** Eclipse Class Decompiler plugin, copyright (c) 2012 Chao Chen (cnfree2000@hotmail.com) ***/
package com.qihoo.gamecenter.sdk.pay.b;

import android.content.Context;
import android.graphics.drawable.Drawable;
import com.qihoo.gamecenter.sdk.pay.res.GSR;
import com.qihoo.gamecenter.sdk.pay.res.b;
import java.lang.reflect.Field;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

public class a {
    public static Drawable a(Context paramContext, String paramString) {
        if (Pattern.compile("[a-zA-Z]*").matcher(paramString).matches()) {
            Drawable localDrawable = null;
            b localb = b.a(paramContext);
            if (localb != null) {
                localDrawable = localb.a(a(paramString));
                if (localDrawable == null)
                    localDrawable = localb.a(1073741839);
            }
            return localDrawable;
        }
        return null;
    }

    public static int a(String paramString) {
        try {
            Field localField = GSR.class.getField("bank_icon_" + paramString.trim().toLowerCase());
            return Integer.valueOf(localField.getInt(localField)).intValue();
        } catch (Exception localException) {}
        return 1073741839;
    }
}